#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>
void* my_memcpy(void* dest, void* src, size_t num)
{
	void* ret = dest;
	while (num--)
	{
		*(char*)dest = *(char*)src;
		dest = (char*)dest+1;
		src = (char*)src+1;
	}
	return ret;
}

int main()
{
	//char arr1[] = "abcdef";
	//char arr2[20] = { 0 };
	int arr1[] = { 1,2,3,44,5 };
	int arr2[20] = { 0 };
	//memcpy(arr2, arr1, 6);
	my_memcpy((char*)arr2, (char*)arr1, 16);
	//printf("%s", arr2);
	for (int i = 0; i < 4; i++)
		printf("%d ", arr2[i]);
	return 0;
}